package vn.gq.udv.db.items;

import android.os.Parcel;
import android.os.Parcelable;

public class ChapterDetail implements Parcelable {

	private int id;
	private String detail;
	private int catId;
	
	public ChapterDetail() {
	}
	
	public ChapterDetail(Parcel in) {
		id = in.readInt();
		detail = in.readString();
		catId = in.readInt();
	}
	
	@Override
	public int describeContents() {
		return 0;
	}

	@Override
	public void writeToParcel(Parcel dest, int flags) {
		dest.writeInt(id);
		dest.writeString(detail);
		dest.writeInt(catId);
	}

	public String getDetail() {
		return detail;
	}

	public void setDetail(String detail) {
		this.detail = detail;
	}

	public int getId() {
		return id;
	}

	public void setId(int id) {
		this.id = id;
	}
	
	public int getCatId() {
		return catId;
	}

	public void setCatId(int catId) {
		this.catId = catId;
	}

	public static final Parcelable.Creator<ChapterDetail> CREATOR = new Parcelable.Creator<ChapterDetail>() {

		@Override
		public ChapterDetail createFromParcel(Parcel source) {
			return new ChapterDetail(source);
		}

		@Override
		public ChapterDetail[] newArray(int size) {
			return new ChapterDetail[size];
		}
	};
}
